package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.JyjcBsExpensesMapper;
import com.ruoyi.system.domain.JyjcBsExpenses;
import com.ruoyi.system.service.IJyjcBsExpensesService;

/**
 * 部所分摊情况Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-07-13
 */
@Service
public class JyjcBsExpensesServiceImpl implements IJyjcBsExpensesService 
{
    @Autowired
    private JyjcBsExpensesMapper jyjcBsExpensesMapper;

    /**
     * 查询部所分摊情况
     * 
     * @param year 部所分摊情况主键
     * @return 部所分摊情况
     */
    @Override
    public JyjcBsExpenses selectJyjcBsExpensesByYear(String year)
    {
        return jyjcBsExpensesMapper.selectJyjcBsExpensesByYear(year);
    }

    /**
     * 查询部所分摊情况列表
     * 
     * @param jyjcBsExpenses 部所分摊情况
     * @return 部所分摊情况
     */
    @Override
    public List<JyjcBsExpenses> selectJyjcBsExpensesList(JyjcBsExpenses jyjcBsExpenses)
    {
        return jyjcBsExpensesMapper.selectJyjcBsExpensesList(jyjcBsExpenses);
    }

    /**
     * 新增部所分摊情况
     * 
     * @param jyjcBsExpenses 部所分摊情况
     * @return 结果
     */
    @Override
    public int insertJyjcBsExpenses(JyjcBsExpenses jyjcBsExpenses)
    {
        return jyjcBsExpensesMapper.insertJyjcBsExpenses(jyjcBsExpenses);
    }

    /**
     * 修改部所分摊情况
     * 
     * @param jyjcBsExpenses 部所分摊情况
     * @return 结果
     */
    @Override
    public int updateJyjcBsExpenses(JyjcBsExpenses jyjcBsExpenses)
    {
        return jyjcBsExpensesMapper.updateJyjcBsExpenses(jyjcBsExpenses);
    }

    /**
     * 批量删除部所分摊情况
     * 
     * @param years 需要删除的部所分摊情况主键
     * @return 结果
     */
    @Override
    public int deleteJyjcBsExpensesByYears(String[] years)
    {
        return jyjcBsExpensesMapper.deleteJyjcBsExpensesByYears(years);
    }

    /**
     * 删除部所分摊情况信息
     * 
     * @param year 部所分摊情况主键
     * @return 结果
     */
    @Override
    public int deleteJyjcBsExpensesByYear(String year)
    {
        return jyjcBsExpensesMapper.deleteJyjcBsExpensesByYear(year);
    }
}
